/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 74646
 * Date: 2022-02-07
 * Time: 10:49
 */
public class TestDome {
    public static void main(String[] args) {
        MyLinkedList myLinkedList = new MyLinkedList();
        myLinkedList.addFirst(1);
        myLinkedList.addFirst(2);
        myLinkedList.addFirst(3);
        myLinkedList.addFirst(4);
        myLinkedList.display();
        System.out.println("============");
        myLinkedList.addLast(10);
        myLinkedList.addLast(20);
        myLinkedList.addLast(30);
        myLinkedList.addLast(40);
        myLinkedList.display();
        System.out.println("==============");
        myLinkedList.removeAllKey(40);
        myLinkedList.display();
        System.out.println("==============");
        myLinkedList.addIndex(1,100);
        myLinkedList.display();
        System.out.println(myLinkedList.size());
        System.out.println("==============");
           boolean ret = myLinkedList.contains(4);
        System.out.println(ret);
        System.out.println("==============");
        myLinkedList.clear();
        myLinkedList.display();
    }
    public static void main1(String[] args) {
        MyLinkedList myLinkedList = new MyLinkedList();
//        for (int i = 5; i < 11; i++) {
//            //myLinkedList.addFirst(i);
//            myLinkedList.addLast(i);
//        }
//        myLinkedList.addLast(16);
//        myLinkedList.addLast(26);
//        myLinkedList.addLast(36);
//        myLinkedList.addLast(46);
//        myLinkedList.addLast(56);
//        myLinkedList.display();
//        System.out.println("--------------");
//        //myLinkedList.remove(5);
//        //myLinkedList.removeAllKey(6);
//        myLinkedList.addIndex(2,15);
//        myLinkedList.addIndex(3,100);
//        myLinkedList.display();
    }
}
